<?php
                      // get timestamp last 24 hours            $date = date('Y-m-d H:i:s', strtotime("-24 hour"));
            $yesterday = strtotime($date);
                                    // grab the feed            $rss = fetch_rss($feedme);

            // prepare the post            $blog = "<ul> \n";
            $countfeed = (count ($rss->items));
                        
            echo "<br\>";
            
            
                // start the loop
            	foreach($rss->items as $item){
  
                    // explode the feed  					
  					// format the datestamp
  					switch($feedtype){
  						case delicious:
  								$published = parse_w3cdtf($item['dc']['date']);	
						
						case rss:
								$published = strtotime($item['pubDate']);                     
                    	case iso8601:                        	    $find[] = 'T';                            	$replace[] = ' ';                            	// convert iso8601 to something we understand                            	$time = str_replace($find, $replace, $item['dateTime.iso8601']);                            	//set the new publish date                            	$published = strtotime($time);
                       }                 
                 
                                			// grab new entires since the last update                		 if ($published >= $yesterday){
                        
                           $Post_Title = htmlentities($item['title']);                           $Post_URL = htmlspecialchars($item['link']);                           $Post_Description = htmlentities($item['description']);                           $Post_Time = date("j M Y", $published);
                                                      // build the post                           
                           $blog .= '<li>'                                . '<a href="'                                . $Post_URL                                . '" '                                . 'title = "'                                . $Post_Time                                . ' " target="myfeed"> '                                . $Post_Title                                . '</a> <br />'                                . $Post_Description                                . '</li>'
                                . "\n";    
                                        
    						$countruns = $countruns+1;                   		}            }
            
            $blog .= "</ul> \n";
?>